import java.util.ArrayList;
import java.util.List;

public class main {

    public static void main(String[] args) {
        final Bean bean = new Bean();
        new Thread(new Runnable() {
            public void run() {
                bean.setA(3);
            }
        }).start();
        new Thread(new Runnable() {
            public void run() {
                System.out.println(bean.getA());
            }
        }).start();
    }
}
